Optimal. Leaf size=356 \[ \frac {\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) x \sqrt {2+d x^2}}{15 d^2 f \sqrt {3+f x^2}}+\frac {(3 b d-4 b f+5 a d f) x \sqrt {2+d x^2} \sqrt {3+f x^2}}{15 d f}+\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}-\frac {\sqrt {2} \left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) \sqrt {2+d x^2} E\left (\tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{15 d^2 f^{3/2} \sqrt {\frac {2+d x^2}{3+f x^2}} \sqrt {3+f x^2}}-\frac {\sqrt {2} (3 b d+2 b f-10 a d f) \sqrt {2+d x^2} F\left (\tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{5 d f^{3/2} \sqrt {\frac {2+d x^2}{3+f x^2}} \sqrt {3+f x^2}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.21, antiderivative size = 356, normalized size of antiderivative = 1.00, number of steps
used = 6, number of rules used = 5, integrand size = 30, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {542, 545, 429,
506, 422} \begin {gather*} -\frac {\sqrt {2} \sqrt {d x^2+2} \left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) E\left (\text {ArcTan}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{15 d^2 f^{3/2} \sqrt {f x^2+3} \sqrt {\frac {d x^2+2}{f x^2+3}}}-\frac {\sqrt {2} \sqrt {d x^2+2} (-10 a d f+3 b d+2 b f) F\left (\text {ArcTan}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{5 d f^{3/2} \sqrt {f x^2+3} \sqrt {\frac {d x^2+2}{f x^2+3}}}+\frac {x \sqrt {d x^2+2} \left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right )}{15 d^2 f \sqrt {f x^2+3}}+\frac {x \sqrt {d x^2+2} \sqrt {f x^2+3} (5 a d f+3 b d-4 b f)}{15 d f}+\frac {b x \left (d x^2+2\right )^{3/2} \sqrt {f x^2+3}}{5 d} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 422
Rule 429
Rule 506
Rule 542
Rule 545
Rubi steps
\begin {align*} \int \left (a+b x^2\right ) \sqrt {2+d x^2} \sqrt {3+f x^2} \, dx &=\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}+\frac {\int \frac {\sqrt {2+d x^2} \left (-3 (2 b-5 a d)+(3 b d-4 b f+5 a d f) x^2\right )}{\sqrt {3+f x^2}} \, dx}{5 d}\\ &=\frac {(3 b d-4 b f+5 a d f) x \sqrt {2+d x^2} \sqrt {3+f x^2}}{15 d f}+\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}+\frac {\int \frac {-6 (3 b d+2 b f-10 a d f)+\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) x^2}{\sqrt {2+d x^2} \sqrt {3+f x^2}} \, dx}{15 d f}\\ &=\frac {(3 b d-4 b f+5 a d f) x \sqrt {2+d x^2} \sqrt {3+f x^2}}{15 d f}+\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}-\frac {(2 (3 b d+2 b f-10 a d f)) \int \frac {1}{\sqrt {2+d x^2} \sqrt {3+f x^2}} \, dx}{5 d f}+\frac {\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) \int \frac {x^2}{\sqrt {2+d x^2} \sqrt {3+f x^2}} \, dx}{15 d f}\\ &=\frac {\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) x \sqrt {2+d x^2}}{15 d^2 f \sqrt {3+f x^2}}+\frac {(3 b d-4 b f+5 a d f) x \sqrt {2+d x^2} \sqrt {3+f x^2}}{15 d f}+\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}-\frac {\sqrt {2} (3 b d+2 b f-10 a d f) \sqrt {2+d x^2} F\left (\tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{5 d f^{3/2} \sqrt {\frac {2+d x^2}{3+f x^2}} \sqrt {3+f x^2}}-\frac {\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) \int \frac {\sqrt {2+d x^2}}{\left (3+f x^2\right )^{3/2}} \, dx}{5 d^2 f}\\ &=\frac {\left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) x \sqrt {2+d x^2}}{15 d^2 f \sqrt {3+f x^2}}+\frac {(3 b d-4 b f+5 a d f) x \sqrt {2+d x^2} \sqrt {3+f x^2}}{15 d f}+\frac {b x \left (2+d x^2\right )^{3/2} \sqrt {3+f x^2}}{5 d}-\frac {\sqrt {2} \left (5 a d f (3 d+2 f)-2 b \left (9 d^2-6 d f+4 f^2\right )\right ) \sqrt {2+d x^2} E\left (\tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{15 d^2 f^{3/2} \sqrt {\frac {2+d x^2}{3+f x^2}} \sqrt {3+f x^2}}-\frac {\sqrt {2} (3 b d+2 b f-10 a d f) \sqrt {2+d x^2} F\left (\tan ^{-1}\left (\frac {\sqrt {f} x}{\sqrt {3}}\right )|1-\frac {3 d}{2 f}\right )}{5 d f^{3/2} \sqrt {\frac {2+d x^2}{3+f x^2}} \sqrt {3+f x^2}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] Result contains complex when optimal does not.
time = 1.26, size = 186, normalized size = 0.52 \begin {gather*} \frac {\sqrt {d} f x \sqrt {2+d x^2} \sqrt {3+f x^2} \left (2 b f+5 a d f+3 b d \left (1+f x^2\right )\right )+i \sqrt {3} \left (-5 a d f (3 d+2 f)+2 b \left (9 d^2-6 d f+4 f^2\right )\right ) E\left (i \sinh ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {2}}\right )|\frac {2 f}{3 d}\right )+i \sqrt {3} (3 d-2 f) (-6 b d+2 b f+5 a d f) F\left (i \sinh ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {2}}\right )|\frac {2 f}{3 d}\right )}{15 d^{3/2} f^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(774\) vs.
\(2(372)=744\).
time = 0.13, size = 775, normalized size = 2.18
method | result | size |
elliptic | \(\frac {\sqrt {\left (f \,x^{2}+3\right ) \left (d \,x^{2}+2\right )}\, \left (\frac {b \,x^{3} \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}{5}+\frac {\left (a d f +3 b d +2 b f -\frac {b \left (12 d +8 f \right )}{5}\right ) x \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}{3 d f}+\frac {\left (6 a -\frac {2 \left (a d f +3 b d +2 b f -\frac {b \left (12 d +8 f \right )}{5}\right )}{d f}\right ) \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )}{2 \sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}-\frac {\left (3 a d +2 a f +\frac {12 b}{5}-\frac {\left (a d f +3 b d +2 b f -\frac {b \left (12 d +8 f \right )}{5}\right ) \left (6 d +4 f \right )}{3 d f}\right ) \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \left (\EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )-\EllipticE \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )\right )}{\sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}\, d}\right )}{\sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}}\) | \(390\) |
risch | \(\frac {x \left (3 b d \,x^{2} f +5 a d f +3 b d +2 b f \right ) \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}}{15 d f}+\frac {\left (-\frac {\left (15 a \,d^{2} f +10 a d \,f^{2}-18 b \,d^{2}+12 b d f -8 b \,f^{2}\right ) \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \left (\EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )-\EllipticE \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )\right )}{\sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}\, d}+\frac {30 a d f \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )}{\sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}-\frac {9 b d \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )}{\sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}-\frac {6 b f \sqrt {3 f \,x^{2}+9}\, \sqrt {2 d \,x^{2}+4}\, \EllipticF \left (\frac {x \sqrt {-3 f}}{3}, \frac {\sqrt {-4+\frac {6 d +4 f}{f}}}{2}\right )}{\sqrt {-3 f}\, \sqrt {d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6}}\right ) \sqrt {\left (f \,x^{2}+3\right ) \left (d \,x^{2}+2\right )}}{15 d f \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}}\) | \(471\) |
default | \(\frac {\sqrt {d \,x^{2}+2}\, \sqrt {f \,x^{2}+3}\, \left (3 b \,d^{3} f^{2} x^{7} \sqrt {-f}+5 a \,d^{3} f^{2} x^{5} \sqrt {-f}+12 b \,d^{3} f \,x^{5} \sqrt {-f}+8 b \,d^{2} f^{2} x^{5} \sqrt {-f}+15 a \,d^{3} f \,x^{3} \sqrt {-f}+10 a \,d^{2} f^{2} x^{3} \sqrt {-f}+15 \sqrt {2}\, \EllipticF \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) a \,d^{2} f \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}-10 \sqrt {2}\, \EllipticF \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) a d \,f^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+15 \sqrt {2}\, \EllipticE \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) a \,d^{2} f \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+10 \sqrt {2}\, \EllipticE \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) a d \,f^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+9 b \,d^{3} x^{3} \sqrt {-f}+30 b \,d^{2} f \,x^{3} \sqrt {-f}+4 b d \,f^{2} x^{3} \sqrt {-f}+9 \sqrt {2}\, \EllipticF \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b \,d^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}-18 \sqrt {2}\, \EllipticF \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b d f \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+8 \sqrt {2}\, \EllipticF \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b \,f^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}-18 \sqrt {2}\, \EllipticE \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b \,d^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+12 \sqrt {2}\, \EllipticE \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b d f \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}-8 \sqrt {2}\, \EllipticE \left (\frac {x \sqrt {3}\, \sqrt {-f}}{3}, \frac {\sqrt {2}\, \sqrt {3}\, \sqrt {\frac {d}{f}}}{2}\right ) b \,f^{2} \sqrt {f \,x^{2}+3}\, \sqrt {d \,x^{2}+2}+30 a \,d^{2} f x \sqrt {-f}+18 b \,d^{2} x \sqrt {-f}+12 b d f x \sqrt {-f}\right )}{15 \left (d f \,x^{4}+3 d \,x^{2}+2 f \,x^{2}+6\right ) d^{2} f \sqrt {-f}}\) | \(775\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [F(-2)]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Exception raised: TypeError} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \left (a + b x^{2}\right ) \sqrt {d x^{2} + 2} \sqrt {f x^{2} + 3}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \left (b\,x^2+a\right )\,\sqrt {d\,x^2+2}\,\sqrt {f\,x^2+3} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________